package com.lvmama.pangolin.enums;

public enum Company {

	LMMXC("驴妈妈", "LMMXC", "LMMXC_C_CODE"), 
	LMMTC("驴妈妈", "LMMTC", "LMMTC_C_CODE"),
	LMMTN("驴妈妈", "LMMTN", "LMMTN_C_CODE"),
	LMMQNR("驴妈妈", "LMMQNR", "LMMQNR_C_CODE"),
	LMMMT("驴妈妈", "LMMMT", "LMMMT_C_CODE"),
	LMM("驴妈妈", "LMM", "LMM_C_CODE"),
	XC("携程", "XC", "XC_C_CODE"), 
	TC("同程", "TC", "TC_C_CODE"), 
	TN("途牛", "TN", "TN_C_CODE"), 
	QNR("去哪儿", "QNR", "QNR_C_CODE"), 
	MT("美团", "MT", "MT_C_CODE"),
	EL("艺龙", "EL", "EL_C_CODE");

	private String name;
	private String code;
	private String value;

	private Company(String name, String code, String value) {
		this.name = name;
		this.code = code;
		this.value = value;
	}

	public static String getNameByCode(String code){
		Company[] companys = Company.values();
		for (Company company : companys) {
			if(company.code.equals(code)){
				return company.name;
			}
		}
		return null;
	}
	
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getValue() {
		return value;
	}

	public void setValue(String value) {
		this.value = value;
	}
	
	
}
